package com.shensi.api.pay.client;


import com.shensi.api.pay.param.request.AddPayOrderParam;
import com.shensi.api.pay.param.request.QuestEnterpriseParam;
import com.shensi.api.pay.pojo.TradeReversePayVO;
import com.shensi.common.core.constant.CloudConstant;
import com.shensi.api.pay.param.ResultData;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.ResponseBody;

import javax.validation.Valid;

@Api(tags = "支付")
@FeignClient(name = CloudConstant.PAY_SERVER, path = "/payment")
public interface PaymentClient {


    /**
     * 天阙支付-被扫支付
     *
     * @param request
     * @param response
     */
    @ApiOperation(value = "天阙支付-被扫支付")
    @PostMapping("/tradeReversePay")
    @ResponseBody
    public ResultData<TradeReversePayVO> tradeReversePay(@Valid @RequestBody AddPayOrderParam payParameter);

    @ApiOperation(value = "天阙支付-被扫支付")
    @PostMapping("/tradeReversePayN")
    @ResponseBody
    public ResultData<TradeReversePayVO> tradeReversePayN(@Valid @RequestBody AddPayOrderParam payParameter);


    /**
     * 订单查询
     *
     * @param payParameter
     * @return
     */
    @ApiOperation(value = "订单查询")
    @PostMapping("/queryTradeReversePayOrder")
    @ResponseBody
    public ResultData<TradeReversePayVO> queryTradeReversePayOrder(@Valid @RequestBody AddPayOrderParam payParameter);


    /**
     * 支付的商户编号查询
     *
     * @param payParameter
     * @return
     */
    @ApiOperation(value = "支付的商户编号查询")
    @PostMapping("/selectPayWayEnterpriseId")
    @ResponseBody
    public String selectPayWayEnterpriseId(@RequestBody QuestEnterpriseParam param);


}
